import React from 'react';
// import {Text, View} from 'react-native';
import { Footer, FooterTab, Button, Text} from 'native-base';
import {withRouter} from 'react-router-native';

class FooterView extends React.Component {
  goPage = (path) =>{
    const {push} = this.props.history;
    push(path)
  }
  render () {
    console.log(this.props);
    return (<Footer>
      <FooterTab>
        <Button onPress={() =>{this.goPage('/home')}}>
          <Text>home</Text>
        </Button>
        <Button onPress={() =>{this.goPage('/follow')}}>
          <Text>follow</Text>
        </Button>
        <Button active onPress={() =>{this.goPage('/mine')}}>
          <Text>mine</Text>
        </Button>
        <Button onPress={() =>{this.goPage('/search')}}>
          <Text>Contact</Text>
        </Button>
      </FooterTab>
    </Footer>);
  }
}

export default withRouter(FooterView);
